using System.Collections.Generic;

namespace Blog.Models.UserServices
{
    public interface IUserService
    {
        AddResult Register(User user);

        void Update(User user);

        bool Exist(string username);

        LoginResult Login(string username, string password);

        bool Authenticate(string username, string password);

        IList<Role> GetRoleByUserId(int userId);

        User GetUserByUsername(string username);

        bool HasRole(int userId, string roleName);

        string EncryptPassword(string password);

        IList<User> GetAllUser();
        IList<Role> Quyen(int id, int index, int size);

        void ChangePassword(string username, string password);

        int DeleteUser(int userId);

        User GetById(int userId);
        IList<User> GetByDepartment(string departmentName);
    }
}